package com.changgou.goods.dao;

import com.changgou.goods.pojo.Spec;
import org.apache.ibatis.annotations.Select;
import tk.mybatis.mapper.common.Mapper;

import java.util.List;

public interface SpecMapper extends Mapper<Spec> {
    //根据商品分类名称查询规格列表
    @Select("select * from tb_spec where template_id in(select template_id FROM tb_category where name = #{name})ORDER BY seq")
    public List<Spec> findSpecListByCategoryName(String name);
}
